package com.sky.mapper;

import com.github.pagehelper.Page;
import com.sky.dto.OrdersConfirmDTO;
import com.sky.dto.OrdersPageQueryDTO;
import com.sky.entity.Orders;
import com.sky.vo.OrderStatisticsVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
 * @program: sky-take-out
 * @description:
 * @author: fmp
 * @create: 2023-04-09 15:10
 * @Version 1.0
 **/
@Mapper
public interface AdminOrderMapper {
    //条件分页订单查询
    Page<Orders> selectByPage(@Param("ordersPageQueryDTO") OrdersPageQueryDTO ordersPageQueryDTO);
    //各个状态的订单数量统计
    Integer selectStatisticsConfirmed(@Param("confirmed") Integer confirmed);
    Integer selectDeliveryInProgress(@Param("deliveryInProgress") Integer deliveryInProgress);
    Integer selectToBeConfirmed(@Param("toBeConfirmed") Integer toBeConfirmed);
    //更改订单状态
    void updateOrderStatues(@Param("ordersConfirmDTO")OrdersConfirmDTO ordersConfirmDTO);
}
